import { EntitySchema } from '@mikro-orm/core';

export class TypechoInvitation {
  id!: number;
  code?: string;
  created?: number = 0;
  uid?: number = 0;
  status?: number = 0;
}

export const TypechoInvitationSchema = new EntitySchema({
  class: TypechoInvitation,
  properties: {
    id: { primary: true, type: 'number' },
    code: { type: 'string', length: 255, nullable: true },
    created: { type: 'number', nullable: true, default: 0 },
    uid: { type: 'number', nullable: true, default: 0 },
    status: { type: 'number', nullable: true, default: 0 },
  },
});
